package com.youlai.boot.modules.country.model.form;

import java.io.Serial;
import java.io.Serializable;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Getter;
import lombok.Setter;
import jakarta.validation.constraints.*;

/**
 * 国家数据表单对象
 *
 * @author liuwanwei
 * @since 2025-02-26 17:48
 */
@Getter
@Setter
@Schema(description = "国家数据表单对象")
public class CountryForm implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    @Schema(description = "主键")
    private Long id;

    @Schema(description = "中文名称")
    @Size(max=64, message="中文名称长度不能超过64个字符")
    private String nameZh;

    @Schema(description = "英文名称")
    @Size(max=64, message="英文名称长度不能超过64个字符")
    private String nameEn;

    @Schema(description = "国家代码")
    @Size(max=8, message="国家代码长度不能超过8个字符")
    private String code;

    @Schema(description = "国旗图标URL")
    @NotBlank(message = "国旗图标URL不能为空")
    @Size(max=255, message="国旗图标URL长度不能超过255个字符")
    private String flagIcon;

    @Schema(description = "排序")
    @NotNull(message = "排序不能为空")
    private Integer sort;


}
